package com.xbongbong.paas.pojo.workflow.nodes.vo;

import com.xbongbong.paas.pojo.workflow.settings.vo.FilterConditionVO;
import lombok.Getter;
import lombok.Setter;
import lombok.ToString;

import java.io.Serializable;
import java.util.List;

/**
 * @author 吴峰
 * @version 1.0
 * @date 2021/5/31 14:46
 * @description 获取多条数据节点
 */
@Getter
@Setter
@ToString
public class ObtainMultiDataNodeVO implements Serializable {


    private static final long serialVersionUID = 4741834836736120649L;
    /**
     * 数据来源 1：从工作表获取
     */
    private Integer dataSources;
    /**
     * 过滤条件
     */
    private List<FilterConditionVO> filterCondition;
    /**
     * 排序字段
     */
    private String orderField;

    private String orderFieldName;

    /**
     * 排序顺序
     */
    private String order;

    /**
     * 无数据执行的事件 1：继续执行；2：中止流程
     */
    private Integer noDataEvent;

    /**
     * 超过限制数据的事件 1： 仅执行限制内的数据 2： 跳过并继续执行 3：中止流程
     */
    private Integer exceedLimitDataEvent;

    /**
     * 触发表单的数据来源是编辑前还是编辑后；编辑前：0；编辑后：1
     */
    private Integer editedData;

    public ObtainMultiDataNodeVO() {
    }

    public ObtainMultiDataNodeVO(Integer editedData, Integer dataSources, List<FilterConditionVO> filterCondition, String orderFieldName, String orderField, String order, Integer noDataEvent, Integer exceedLimitDataEvent) {
        this.editedData = editedData;
        this.dataSources = dataSources;
        this.filterCondition = filterCondition;
        this.orderField = orderField;
        this.orderFieldName = orderFieldName;
        this.order = order;
        this.noDataEvent = noDataEvent;
        this.exceedLimitDataEvent = exceedLimitDataEvent;
    }
}
